From d3b483f9776fbae19a2354a2a3c81536fcbdd37a Mon Sep 17 00:00:00 2001 From: Fabio Fantoni Date: Tue, 21 Jan 2014 14:51:08 +0100 Subject: [PATCH] tools/hotplug: fix bug on xendomains using xl Make rdname function work with xl. The rdname function not support json output of xl commands and this cause problems using xl, for example the check if domUs are already running (because they have been restored) on domUs autostart does not succeed and the domain is created in any case, causing xl create to fail. Signed-off-by: Fabio Fantoni Acked-by: Ian Campbell --- tools/hotplug/Linux/init.d/xendomains | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/hotplug/Linux/init.d/xendomains b/tools/hotplug/Linux/init.d/xendomains index 38371af6a4..59f1e3df4d 100644 --- a/tools/hotplug/Linux/init.d/xendomains +++ b/tools/hotplug/Linux/init.d/xendomains @@ -186,7 +186,7 @@ contains_something() rdname() { NM=$($CMD create --quiet --dryrun --defconfig "$1" | - sed -n 's/^.*(name \(.*\))$/\1/p') + sed -n 's/^.*(name \(.*\))$/\1/p;s/^.*"name": "\(.*\)",$/\1/p') } rdnames() -- 2.30.2